//
//  ActivityDetailView.m
//  豆瓣
//
//  Created by dllo on 15/10/27.
//  Copyright (c) 2015年 蓝鸥科技. All rights reserved.
//

#import "ActivityDetailView.h"

@implementation ActivityDetailView

- (void)dealloc
{
    [_nameLabel release];
    [_timeLabel release];
    [_kindLabel release];
    [_sponsorLabel release];
    [_cImage release];
    [_contentLabel release];
    [_addressLabel release];
    [_aLabel release];
    [super dealloc];
}

- (instancetype)initWithFrame:(CGRect)frame
{
    [super initWithFrame:frame];
    if (self) {
        
        [self createSubViews];
        
    }
    return self;
}

- (void)createSubViews
{
    self.cImage = [[UIImageView alloc] initWithFrame:CGRectMake(10, 120, 120, 170)];
    self.cImage.backgroundColor = [UIColor grayColor];
    [self addSubview:self.cImage];
    [self.cImage release];
    
    
    self.nameLabel = [[UILabel alloc] initWithFrame:CGRectMake(10, 40, 355, 60)];
    
    self.nameLabel.backgroundColor = [UIColor whiteColor];
    
    [self addSubview:self.nameLabel];
    
    self.nameLabel.textAlignment = NSTextAlignmentLeft;
    
    self.nameLabel.font = [UIFont systemFontOfSize:21];
    
    self.nameLabel.numberOfLines = 0;
    
    [self.nameLabel release];
    

    
    UIImageView *ptime = [[UIImageView alloc] initWithFrame:CGRectMake(160, 120, 20, 20)];
    
    ptime.backgroundColor = [UIColor whiteColor];
    
    [self addSubview:ptime];
    
    [ptime setImage:[UIImage imageNamed:@"icon_date_blue.png"]];
    
    [ptime release];
    
    
    
    UIImageView *pname = [[UIImageView alloc] initWithFrame:CGRectMake(160, 165, 20, 20)];
    
    pname.backgroundColor = [UIColor whiteColor];
    
    [self addSubview:pname];
    
    [pname setImage:[UIImage imageNamed:@"icon_sponsor_blue.png"]];
    
    [pname release];
    
    
    
    UIImageView *pcategory = [[UIImageView alloc] initWithFrame:CGRectMake(160, 215, 20, 20)];
    
    pcategory.backgroundColor = [UIColor whiteColor];
    
    [self addSubview:pcategory];
    
    [pcategory setImage:[UIImage imageNamed:@"icon_catalog_blue.png"]];
    
    [pcategory release];
    
    
    
    UIImageView *paddress = [[UIImageView alloc] initWithFrame:CGRectMake(160, 260, 20, 20)];
    
    paddress.backgroundColor = [UIColor whiteColor];
    
    [self addSubview:paddress];
    
    [paddress setImage:[UIImage imageNamed:@"icon_spot_blue.png"]];
    
    [paddress release];
    

    
    self.timeLabel = [[UILabel alloc] initWithFrame:CGRectMake(180, 120, 180, 20)];
    
    self.timeLabel.backgroundColor = [UIColor whiteColor];
    
    [self addSubview:self.timeLabel];
    
    [self.timeLabel release];
    
    self.timeLabel.font = [UIFont systemFontOfSize:15];
    
    
    
    self.sponsorLabel = [[UILabel alloc] initWithFrame:CGRectMake(180, 165, 180, 20)];
    
    self.sponsorLabel.backgroundColor = [UIColor whiteColor];
    
    [self addSubview:self.sponsorLabel];
    
    [self.sponsorLabel release];
    
    self.sponsorLabel.font = [UIFont systemFontOfSize:15];
    
    
    
    self.kindLabel = [[UILabel alloc] initWithFrame:CGRectMake(180, 215, 180, 20)];
    
    self.kindLabel.backgroundColor = [UIColor whiteColor];
    
    [self addSubview:self.kindLabel];
    
    [self.kindLabel release];
    
    self.kindLabel.font = [UIFont systemFontOfSize:15];
    
    
    
    self.addressLabel = [[UILabel alloc] initWithFrame:CGRectMake(180, 260, 180, 20)];
    
    self.addressLabel.backgroundColor = [UIColor whiteColor];
    
    [self addSubview:self.addressLabel];
    
    [self.addressLabel release];
    
    self.addressLabel.font = [UIFont systemFontOfSize:15];
    
    self.addressLabel.numberOfLines = 0;
    

    
    self.contentLabel = [[UILabel alloc] initWithFrame:CGRectMake(10, 300, 355, 200)];
    
    self.contentLabel.backgroundColor = [UIColor whiteColor];
    
    [self addSubview:self.contentLabel];
    
    [self.contentLabel release];
    
    self.contentLabel.numberOfLines = 0;


}













/*
// Only override drawRect: if you perform custom drawing.
// An empty implementation adversely affects performance during animation.
- (void)drawRect:(CGRect)rect {
    // Drawing code
}
*/

@end
